package io.renren.modules.dictionary.service.impl;

import io.renren.modules.dictionary.entity.DictionaryCustomEntity;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

import io.renren.modules.dictionary.dao.DictionaryDao;
import io.renren.modules.dictionary.entity.DictionaryEntity;
import io.renren.modules.dictionary.service.DictionaryService;



/**
 * @author 杨帅
 */
@Service("dictionaryService")
public class DictionaryServiceImpl implements DictionaryService {
	@Autowired
	private DictionaryDao dictionaryDao;

	@Override
	public int queryTypeId(Map<String, Object> map) {
		return dictionaryDao.queryTypeId(map);
	}

	@Override
	public DictionaryEntity queryObject(Integer dictionaryid){
		return dictionaryDao.queryObject(dictionaryid);
	}
	
	@Override
	public List<DictionaryEntity> queryList(Map<String, Object> map){
		return dictionaryDao.queryList(map);
	}

	@Override
	public List<DictionaryCustomEntity> queryListByTypeName(Map<String, Object> map) {
		return dictionaryDao.queryListByTypeName(map);
	}

	@Override
	public int queryByTypeNameTotal(Map<String, Object> map) {
		return dictionaryDao.queryByTypeNameTotal(map);
	}

	@Override
	public int queryTotal(Map<String, Object> map){
		return dictionaryDao.queryTotal(map);
	}
	
	@Override
	public void save(DictionaryEntity dictionary){
		dictionaryDao.save(dictionary);
	}
	
	@Override
	public void update(DictionaryEntity dictionary){
		dictionaryDao.update(dictionary);
	}
	
	@Override
	public void delete(Integer dictionaryid){
		dictionaryDao.delete(dictionaryid);
	}
	
	@Override
	public void deleteBatch(Integer[] dictionaryids){
		dictionaryDao.deleteBatch(dictionaryids);
	}

	@Override
	public List<DictionaryEntity> searchByTypename(String typename) {
		return dictionaryDao.searchByTypename(typename);
	}

	@Override
	public void deleteBatchByDicTypeId(Integer dictypeid) {
		dictionaryDao.deleteBatchByDicTypeId(dictypeid);
	}

	@Override
	public DictionaryEntity queryObjectByDateTypeName(String dateTypeName) {
		return dictionaryDao.queryObjectByDateTypeName(dateTypeName);
	}

	@Override
	public void updateByDataTypeName(DictionaryEntity dictionaryEntity) {
		dictionaryDao.updateByDataTypeName(dictionaryEntity);
	}

}
